package com.huanbao.saas.service.impl;

import com.huanbao.common.pojo.sassrabc.SassUser;
import com.huanbao.common.pojo.sassrabc.vo.SassUserDetail;
import com.huanbao.saas.dao.AdminDao;
import com.huanbao.saas.dao.MenuDao;
import com.huanbao.saas.service.AdminService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

@Service
public class AdminServiceImpl implements AdminService {

    @Autowired
    private AdminDao adminDao;

    @Autowired
    private MenuDao menuDao;

    @Override
    public SassUserDetail getSassUserByName(String loginName) {
        SassUserDetail sassUserDetail = new SassUserDetail();
        SassUser sassUser = adminDao.getSassUserByName(loginName);
        sassUserDetail.setSassUser(sassUser);
        if(null != sassUser){
            //获取菜单
//            menuDao
        }
        return sassUserDetail;
    }
}
